/**
 * Copyright &copy; 2012-2016 <a href="https://github.com/thinkgem/jeesite">JeeSite</a> All rights reserved.
 */
package com.thinkgem.jeesite.modules.hk.shop.entity.activity;

import com.thinkgem.jeesite.modules.hk.shop.entity.product.HkShopProduct;
import org.hibernate.validator.constraints.Length;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;

import com.thinkgem.jeesite.common.persistence.DataEntity;

/**
 * 乐购折扣专场Entity
 * @author 罗天文
 * @version 2018-05-16
 */
public class HkShopDiscountProduct extends DataEntity<HkShopDiscountProduct> {
	
	private static final long serialVersionUID = 1L;
	private HkShopDiscount productDiscount;		// 折扣id 父类
	private HkShopProduct product;		// 商品id
	private Date beginTime;		// 开始时间
	private Date endTime;		// 结束时间
	private String state;		// 状态
	private String activityType;		// 活动类型
	private String integral;		// 乐币
	private String activityPrice;		// 活动乐币
	private String discount;		// 折扣
	private String activityStocks;		// 活动库存
	
	public HkShopDiscountProduct() {
		super();
	}

	public HkShopDiscountProduct(String id){
		super(id);
	}

	public HkShopDiscountProduct(HkShopDiscount productDiscount){
		this.productDiscount = productDiscount;
	}

	@Length(min=0, max=32, message="折扣id长度必须介于 0 和 32 之间")
	public HkShopDiscount getProductDiscount() {
		return productDiscount;
	}

	public void setProductDiscount(HkShopDiscount productDiscount) {
		this.productDiscount = productDiscount;
	}
	
	public HkShopProduct getProduct() {
		return product;
	}

	public void setProduct(HkShopProduct product) {
		this.product = product;
	}
	
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	public Date getBeginTime() {
		return beginTime;
	}

	public void setBeginTime(Date beginTime) {
		this.beginTime = beginTime;
	}
	
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	public Date getEndTime() {
		return endTime;
	}

	public void setEndTime(Date endTime) {
		this.endTime = endTime;
	}
	
	@Length(min=0, max=1, message="状态长度必须介于 0 和 1 之间")
	public String getState() {
		return state;
	}

	public void setState(String state) {
		this.state = state;
	}
	
	@Length(min=0, max=2, message="活动类型长度必须介于 0 和 2 之间")
	public String getActivityType() {
		return activityType;
	}

	public void setActivityType(String activityType) {
		this.activityType = activityType;
	}
	
	@Length(min=0, max=11, message="乐币长度必须介于 0 和 11 之间")
	public String getIntegral() {
		return integral;
	}

	public void setIntegral(String integral) {
		this.integral = integral;
	}
	
	@Length(min=0, max=11, message="活动乐币长度必须介于 0 和 11 之间")
	public String getActivityPrice() {
		return activityPrice;
	}

	public void setActivityPrice(String activityPrice) {
		this.activityPrice = activityPrice;
	}
	
	public String getDiscount() {
		return discount;
	}

	public void setDiscount(String discount) {
		this.discount = discount;
	}
	
	@Length(min=0, max=11, message="活动库存长度必须介于 0 和 11 之间")
	public String getActivityStocks() {
		return activityStocks;
	}

	public void setActivityStocks(String activityStocks) {
		this.activityStocks = activityStocks;
	}
	
}